/*    */ package com.zimbra.cs.service.formatter;
/*    */ 
/*    */ import com.zimbra.common.service.ServiceException;
/*    */ import com.zimbra.cs.service.UserServletContext;
/*    */ import com.zimbra.cs.service.UserServletException;
/*    */ import java.io.IOException;
/*    */ import javax.servlet.http.HttpServletResponse;
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ public class TarFormatter
/*    */   extends ArchiveFormatter
/*    */ {
/*    */   public String[] getDefaultMimeTypes()
/*    */   {
/* 29 */     return new String[] { "application/x-tar" };
/*    */   }
/*    */   
/*    */   public FormatterFactory.FormatType getType()
/*    */   {
/* 34 */     return FormatterFactory.FormatType.TAR;
/*    */   }
/*    */   
/*    */ 
/*    */   protected ArchiveFormatter.ArchiveInputStream getInputStream(UserServletContext context, String charset)
/*    */     throws IOException, ServiceException, UserServletException
/*    */   {
/* 41 */     return new TarArchiveInputStream(context.getRequestInputStream(-1L), charset);
/*    */   }
/*    */   
/*    */ 
/*    */   protected ArchiveFormatter.ArchiveOutputStream getOutputStream(UserServletContext context, String charset)
/*    */     throws IOException
/*    */   {
/* 48 */     return new TarArchiveOutputStream(context.resp.getOutputStream(), charset);
/*    */   }
/*    */ }


/* Location:              /home/mint/zimbrastore.jar!/com/zimbra/cs/service/formatter/TarFormatter.class
 * Java compiler version: 7 (51.0)
 * JD-Core Version:       0.7.1
 */